package com.yunbiao.ybbusstopplate.utils;

import com.example.library_hy_advert.system.Cache;
import com.example.library_hy_advert.system.ScreenType;

public class ScreenPikerUtils {

    //    public static boolean isMasterScreen(){
//        int screenOrdinal = Cache.getInt(Cache.Key.SCREEN_TYPE, Cache.Default.SCREEN_TYPE_ORDINAL);
//        int flag = screenOrdinal == 0 ? ScreenType.MASTER.getValue() : ScreenType.Sub.getValue();
//        return flag == ScreenType.MASTER.getValue();
//    }

    public static boolean isMasterScreen() {
        int screenOrdinal = Cache.getInt(Cache.Key.SCREEN_TYPE, Cache.Default.SCREEN_TYPE_ORDINAL);
        return screenOrdinal == 0;
    }

    public static boolean isSubScreen() {
        int screenOrdinal = Cache.getInt(Cache.Key.SCREEN_TYPE, Cache.Default.SCREEN_TYPE_ORDINAL);
        return screenOrdinal == 1;
    }

    public static int getScreenType() {
        return Cache.getInt(Cache.Key.SCREEN_TYPE, Cache.Default.SCREEN_TYPE_ORDINAL);
    }

}
